var ActionJumpBy = require('./../../../../FrameWork/Action/ActionJumpBy');
var _ = require('./../../../../FrameWork/we_underscore');
var Utils = require('./../../../../FrameWork/Utils/Utils');
cc.Class(
{
    extends: ActionJumpBy,

    getAction()
    {
        var baseAct = this._super();

        var acts = this.addCallFunc([baseAct], function()
        {
            this.node.destroy();
        }.bind(this));
        var action = cc.sequence(acts);
        return action;
    },

    getPosBy()
    {
        var posBy = this._super();
        var x = _.random(0, posBy.x) * Utils.randPlusMinus();
        return new cc.Vec2(x, posBy.y);
    }
});